<?php

namespace app\adminapi\validate\room\department;


use app\common\validate\BaseValidate;


/**
 * 科室设备记录验证器
 * Class RoomDepartmentDeviceLogValidate
 * @package app\adminapi\validate\room
 */
class RoomDepartmentDeviceLogValidate extends BaseValidate
{

     /**
      * 设置校验规则
      * @var string[]
      */
    protected $rule = [
        'id' => 'require',
        'cid' => 'require',
        'rid' => 'require',
        'device_id' => 'require',
        'coefficient' => 'require',
        'price' => 'require',
        'base_number' => 'require',
        'reading' => 'require',
        'use_total' => 'require',
        'lift_fee' => 'require',
        'second_pressure_fee' => 'require',
        'total_fee' => 'require',

    ];


    /**
     * 参数描述
     * @var string[]
     */
    protected $field = [
        'id' => 'id',
        'cid' => '院区',
        'rid' => '房间',
        'device_id' => '设备',
        'coefficient' => '设备系数',
        'price' => '水电价',
        'base_number' => '底数',
        'reading' => '读数',
        'use_total' => '使用量',
        'lift_fee' => '电梯费',
        'second_pressure_fee' => '二次压力费',
        'total_fee' => '总费用',

    ];


    /**
     * @notes 添加场景
     * @return RoomDepartmentDeviceLogValidate
     * @author likeadmin
     * @date 2024/02/26 16:32
     */
    public function sceneAdd()
    {
        return $this->only(['cid','rid','device_id','coefficient','price','base_number','reading','use_total','lift_fee','second_pressure_fee','total_fee']);
    }


    /**
     * @notes 编辑场景
     * @return RoomDepartmentDeviceLogValidate
     * @author likeadmin
     * @date 2024/02/26 16:32
     */
    public function sceneEdit()
    {
        return $this->only(['id','cid','rid','device_id','coefficient','price','base_number','reading','use_total','lift_fee','second_pressure_fee','total_fee']);
    }


    /**
     * @notes 删除场景
     * @return RoomDepartmentDeviceLogValidate
     * @author likeadmin
     * @date 2024/02/26 16:32
     */
    public function sceneDelete()
    {
        return $this->only(['id']);
    }


    /**
     * @notes 详情场景
     * @return RoomDepartmentDeviceLogValidate
     * @author likeadmin
     * @date 2024/02/26 16:32
     */
    public function sceneDetail()
    {
        return $this->only(['id']);
    }

}